#include "tcpClient.hpp"
#include <memory>

void Usage(string proc)
{
    cout << "\nUsage\t" << proc << " serverip serverport" << endl;
}

int main(int argc, char* argv[])
{
    if (argc != 3)
    {
        Usage(argv[0]);
        exit(USAGE_ERR);
    }
    string ip(argv[1]);
    uint16_t port = atoi(argv[2]);
    unique_ptr<tcpClient> tcli(new tcpClient(ip, port));
    tcli->initClient();
    tcli->start();
    return 0;
}